//
//  IndexNaviButton.swift
//  browser
//
//  Created by Kotori on 2021/6/10.
//

import SwiftUI

struct IndexNaviButton: View {
    var btnDelegate: IndexBtnDelegate?
    
    var body: some View {
        HStack {
            Button {
                btnDelegate?.goBack()
            } label: {
                Image(systemName: "chevron.backward").imageScale(.large)
            }.padding()
            
            Divider().frame(width: 0)
            
            Button {
                btnDelegate?.goForward()
            } label: {
                Image(systemName: "chevron.forward").imageScale(.large)
            }.padding()
        }
        .accentColor(.black)
        .frame(width: 110, height: 50, alignment: .center)
        .background(Color(.systemGray6))
        .cornerRadius(25)
        .shadow(color: Color(.systemGray3), radius: 10, x: 5, y: 5)
        
    }
}

struct IndexNaviButton_Previews: PreviewProvider {
    static var previews: some View {
        IndexNaviButton()
    }
}
